using System;

namespace NUnit.Behave
{
    public class ConsoleFormatter
    {
        public static string FormatMessage(string message, MessageType messageType)
        {
            switch (messageType)
            {
                case MessageType.Story_Title:
                    return "Story: " + message;
                case MessageType.Story_As_A:
                    return "\tAs a " + message;
                case MessageType.Story_I_Want:
                    return "\tI want " + message;
                case MessageType.Story_So_That:
                    return "\tSo that " + message;
                case MessageType.Scenario:
                    return "Scenario: " + message;
                case MessageType.Given:
                    return "\tGiven " + message;
                case MessageType.Given_And:
                    return "\tAnd " + message;
                case MessageType.Given_And_Pending:
                    return "\tAnd " + message + " <pending action>";
                case MessageType.Given_Pending:
                    return "\tGiven " + message + " <pending action>";
                case MessageType.Then:
                    return "\tThen " + message;
                case MessageType.Then_And:
                    return "\tAnd " + message;
				case MessageType.Then_And_Pending:
					return "\tAnd " + message + " <pending action>";
                case MessageType.Then_Pending:
                    return "\tThen " + message + " <pending action>";
                case MessageType.When:
                    return "\tWhen " + message;
                case MessageType.When_And:
                    return "\tAnd " + message;
                case MessageType.When_Pending:
                    return "\tWhen " + message + " <pending action>";

                default:
                    throw new ArgumentOutOfRangeException("messageType");
            }
        }
    }
}